package com.cnswhy.cloud.server.core.wallet;

import com.cnswhy.cloud.server.common.entity.enumeration.SubWalletType;
import com.cnswhy.cloud.server.common.entity.enumeration.TransType;
import com.cnswhy.cloud.server.common.entity.enumeration.WalletType;
import com.cnswhy.cloud.server.core.entity.CustomerWallet;

public interface WalletService {
    CustomerWallet getCustomerWalletById(Long walletId);
    CustomerWallet getCustomerWallet(Long customerId, WalletType walletType);
    CustomerWallet checkAndCreate(Long customerId, WalletType walletType,Long initBalance);
    CustomerWallet create(Long customerId, WalletType walletType,Long initBalance);
    CustomerWallet add(Long customerId, WalletType walletType, TransType transType, Long transAmt,String orderId);
    CustomerWallet add(Long customerId, WalletType walletType, TransType transType, Long transAmt,String orderId,String spellOrderId,String splitFrom,int splitLevel);
    boolean checkDed(Long customerId, WalletType walletType, Long transAmt);
    CustomerWallet ded(Long customerId, WalletType walletType, TransType transType, Long transAmt,String orderId);
    CustomerWallet fronzen(Long customerId, WalletType walletType, TransType transType, Long transAmt,String orderId);
    CustomerWallet unfronzen(Long customerId, WalletType walletType, TransType transType, Long transAmt,String orderId);
    CustomerWallet unfronzenAndDed(Long customerId, WalletType walletType, TransType transType, Long transAmt,String orderId);
    void transfer(Long customerId, WalletType walletType, TransType transType, Long transAmt);
}
